#+_+ coding:utf-8 +_+

import urllib2

__author__ = 'cz'


class Response(object):
    _f = None

    def __init__(self, f):
        self._f = f

    def body(self):
        body = self._f.read()
        return body

    def url(self):
        return self._f.geturl()

    def headers(self):
        return self._f.info()

    def code(self):
        return self._f.code()

